package com.xjoyt.pay.share.interfaces;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.xjoyt.pay.dto.ExecuteResult;
import com.xjoyt.pay.dto.PageParam;
import com.xjoyt.pay.dto.PageResult;
import com.xjoyt.pay.share.params.EmailPageParam;
import com.xjoyt.pay.share.params.EmailParam;
import com.xjoyt.pay.share.po.Email;

public interface EmailContract {

	@RequestMapping("sendCode")
	ExecuteResult<String> sendEmail(EmailParam param) throws Exception;

	@RequestMapping(value = "validateCode", method = RequestMethod.POST)
	ExecuteResult<String> validateCode(EmailParam param) throws Exception;

	@RequestMapping(value = "removeCode", method = RequestMethod.POST)
	ExecuteResult<?> removeCode(EmailParam param) throws Exception;

	@RequestMapping(value = "loadPage", method = RequestMethod.POST)
	PageResult<Email> loadPage(PageParam<EmailPageParam> param);

}
